<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%-- 
    JSP Name : jspName.jsp
    Description : 설명을 기술합니다.
    author ETLee
    since 2012. 6. 28.
    version 1.0
    Modification Information
       since          author              description
    ===========    =============    ===========================
    2012. 6. 28.     ETLee     최초 생성
--%>

<%@ include file="/WEB-INF/jsp/com/include/declare.jspf" %>
<%@ include file="/WEB-INF/jsp/com/include/doctype.jspf" %>
<body>
    <div class="boardlist-wrap">
        <div class="list-status-wrap">
    <c:choose>
        <c:when test="${resultList!=null}">
            <p class="list-status">Page <b><c:out value="${paginationInfo.currentPageNo}"/></b>/<c:out value="${paginationInfo.totalPageCount}"/></p>
            <p class="result-status"><b><c:out value="${paginationInfo.totalRecordCount}"/></b>건의 검색결과가 있습니다.</p>
        </c:when>
        <c:otherwise>
            <p class="list-status">Page <b>0</b>/0</p>
            <p class="result-status"><b>0</b>건의 검색결과가 있습니다.</p>
        </c:otherwise>
    </c:choose>
        </div>
        <table class="salesman-search" summary="이미지, 내용">
        <caption>검색 결과 리스트</caption>
        <colgroup>
            <col width="25%" />
            <col width="75%" />
        </colgroup>
        <thead>
        <tr>
            <th scope="col">이미지</th>
            <th scope="col">내용</th>
        </tr>
        </thead>
        <tbody>
    <c:choose>
        <c:when test="${paginationInfo.totalRecordCount > 0}">
    <c:set var="rowNum" value="${ paginationInfo.totalRecordCount - (paginationInfo.currentPageNo-1)* paginationInfo.pageSize}" />
    <c:forEach var="result" items="${ resultList }" varStatus="status">
        <tr>
            <td class="center">
                <div class="salesman-thumb">
                <c:if test="${ result.psnPhtgExpsSt != 'N' }">
                    <c:choose>
                        <c:when test="${ not empty result.cmPhtgNm }">
                            <img src='/kr/file/imagePathView.do?nrFilNm=cmst/${result.cmPhtgNm}' width='114px' height='123px' alt=''/>
                        </c:when>
                        <c:when test="">
                            <img src="http://tops.hmc.co.kr/upload/photo/${result.cmEeno}.jpg" style="width:114px; height:123px;" />
                        </c:when>
                        <c:otherwise>
                            <img src="http://tops.hmc.co.kr/upload/photo/${result.cmEeno}.jpg" style="width:114px; height:123px;" />
                        </c:otherwise>
                    </c:choose>
                </c:if>
                </div>
            </td>
            <td class="last">
                <div class="salesman-information">
                    <ul>
                        <li>
                            <em class="d-tit"><img src="/kr/images/layerpopup/txt_branch01.gif" alt="성명" /></em>
                            <p class="d-txt"><c:out value="${ result.cmNm }"/></p>
                        </li>
                        <li>
                            <em class="d-tit"><img src="/kr/images/layerpopup/txt_branch02.gif" alt="소속" /></em>
                            <p class="d-txt"><c:out value="${ result.brNm }"/></p>
                        </li>
                        <li>
                            <em class="d-tit"><img src="/kr/images/layerpopup/txt_branch03.gif" alt="휴대폰" /></em>
                            <p class="d-txt"><c:out value="${ result.cmCcpc }"/></p>
                        </li>
                        <li>
                            <em class="d-tit"><img src="/kr/images/layerpopup/txt_branch04.gif" alt="이메일" /></em>
                            <p class="d-txt"><c:out value="${ result.cmEml }"/></p>
                        </li>
                        <li>
                            <em class="d-tit"><img src="/kr/images/layerpopup/txt_branch05.gif" alt="인사말" /></em>
                            <p class="d-txt"><c:out value="${ result.cmGret }"/></p>
                        </li>
                    </ul>
                    <c:if test="${result.cnsPsblYn != 'N'}">
                    <a href="javascript:cMstSeleted('${result.cmEeno}','${result.brCd}','${result.ctrCd}','${result.brNm}','${result.cmNm}','${result.cmCcpc}','${result.cmEml}');"><img src="/kr/images/layerpopup/btn_application.gif" alt="구매상담신청" class="application" /></a>
<!--                     <a href="/kr/pur/purCounselReqPaging.do"><img src="/kr/images/layerpopup/btn_application.gif" alt="구매상담신청" class="application" /></a> -->
<%--                     <a href="javascript:fnPurView('${result.cmEeno}');"><img src="/kr/images/layerpopup/btn_application.gif" alt="구매상담신청" class="application" /></a> --%>
                    </c:if>
                </div>
            </td>
        </tr>
    </c:forEach>
        </c:when>
        <c:otherwise>
        <tr>
            <td colspan="2" class="center last">검색된 결과가 없습니다.</td>
        </tr>
        </c:otherwise>
    </c:choose>
        </tbody>
        </table>
    </div>
<c:if test="${paginationInfo.totalRecordCount > 0 }">
    <div class="paging">
        <able:pagination paginationInfo="${paginationInfo}" type="image" jsFunction="fnLinkPage" />
    </div>
</c:if>
</body>
</html>